<template>
  <div>
    App..
    <button @click="getPost">GET</button>
    <button @click="addPost">POST</button>
    <button @click="putPost">PUT</button>
    <button @click="patchPost">PATCH</button>
    <button @click="delPost">DELETE</button>
  </div>
</template>


<script>
import axios from "axios";
export default {
  name: "App",
  methods: {
   async getPost() { 
      try {
        const result = await axios({
          method: 'GET',
          url: "http://localhost:8080/api/admin/product/baseTrademark/getTrademarkList",
         
        });
        console.log(result.data);
      } catch (error) {
        console.log(error);
      }
    
    },

    async addPost() {
      try {
        const result = await axios({
          method: 'post',
          url: "http://localhost:8080/api/admin/product/baseTrademark/save",
          data: {
            logoUrl: "https://jiaduobao.com",
            tmName: "加多宝"
          },
        });
        console.log(result);
      } catch (error) {
        console.log(error);
      }
    },
  },
}
</script>
<style>

</style>